#pragma once

#include <mswin/shared_resource.h>

namespace My {

template <typename D> class AsyncView;
/*
template <typename D>
class AsyncViewBuffer : private mswin::shared_resource {
public:
	typedef D DataType;
public:
	AsyncViewBuffer(AsyncView<D> &);
	bool IsEmpty() const;
	bool IsInvalidateOnChange();
	void InvalidateOnChange();
	void ResetInvalidateOnChange();
	bool WasOncePainted();
	void ResetPaintedStatus();
	void ChangeBySwap(DataType &);
	void Release();
public:
	// Synchronization
	friend class LockedAccessor;
	class LockedAccessor {
		AsyncViewBuffer &			m_Buffer;
		AsyncViewBuffer::auto_lock	m_Lock;
	public:
		LockedAccessor(AsyncViewBuffer &);
		bool IsEmpty() const;
		const DataType & GetData() const;
		void OncePainted();
	};
private:
	AsyncView<D> &		m_View;
	volatile bool		m_InvalidateViewOnChange;
	volatile bool		m_WasOncePainted;
	DataType			m_Data;
};
*/
class AsyncViewBase {
};

template <typename D>
class AsyncView : public AsyncViewBase {
public:
	typedef D	DataType;
private:

};

} // My
